<template  >
  <el-scrollbar  class="scrollbar" wrap-class="scrollbar-wrapper">
    <el-menu :default-active="$route.path" mode="vertical" router :collapse="isCollapse">
      <div v-for=" (item,index)  in  (SidebarData=='2'?navdata :accountdata)" :key="index">
        <el-submenu  :index="index">
          <template  class="template1" slot="title">{{item.meta.title}}</template>
          <el-menu-item
            v-for="child  in item.children"
            :index="child.path"
            :key="child.path"
          >{{child.meta.title}}</el-menu-item>
        </el-submenu>
      </div>
    </el-menu>
  </el-scrollbar>
</template>
<script>
import { accountdata } from "@/assets/js/accountdata.js"; //企业客户
import { navdata } from "@/assets/js/navdata.js"; //企业客户
export default {
  data() {
    return {
      navdata: navdata,
      accountdata:accountdata,
      isCollapse:false
    };
     
  },
  methods:{
 
  },
   props:["SidebarData"],
  components: {},
  computed: {}
};
</script>
<style lang="scss"  >


// .el-submenu__title:focus, .el-submenu__title:hover, .el-submenu__title.is-active{
//     outline: 0 !important;
//     color:brown !important;
//     background: none !important;
// }


.el-submenu {
  :hover {
    border-left: 6px solid rgb(30, 209, 24);
  }
  
     .is-active{
       //鼠标按下，激活状态
     background-color: red !important;
  }
  .el-menu-item {
    // height: 80px !important;
    // line-height:80px !important;

    &:hover {
      background-color: #f3f6f9 !important;
    }
  }
  .el-submenu__title {
    &:hover {
      background-color: #f3f6f9  !important;
    }
    .el-submenu__icon-arrow {
      //箭头
     // color: #b4b8c5;
      &:hover {
      border-left: #f3f6f9 !important;
    }
    }
  
  }
}

</style>